package io.bdmc.modules.bss.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * <p>
 * 实体
 * </p>
 *
 * @author ping
 * @since 2020-06-30
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
// "DeviceMeasureEvent对象", description = "")
public class DeviceMeasureEvent extends Model<DeviceMeasureEvent> {

    private static final long serialVersionUID = 1L;

    // "自增id")
    @TableId(value = "event_id", type = IdType.AUTO)
    private Integer eventId;

    // "测量id")
    private Integer measureId;

    // "部门id")
    private Long deptId;

    // "事件编号")
    private Integer eventNumber;

    // "事件类型")
    private String eventType;

    // "事件代码")
    private String eventCode;

    // "位置(km)")
    private BigDecimal eventPropagationDistance;

    // "衰减系数")
    private BigDecimal attenuationCoefficient;

    // "事件衰耗(dB)")
    private BigDecimal eventLoss;

    // "反射率")
    private BigDecimal reflcetivity;

    // "总损耗")
    private BigDecimal totalLosses;

    // "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createTime;

    // "创建人")
    private String createBy;

    @Override
    public Serializable pkVal() {
        return this.eventId;
    }

}
